package com.ljs.liojbackendjudgeservice.judge.controlelr.inner;

import com.ljs.libackendmodel.model.entity.QuestionSubmit;
import com.ljs.liojbackendjudgeservice.judge.JudgeService;
import com.ljs.liojbackendserviceclient.service.JudgeFeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * 该服务仅在内部使用
 */
@RestController
@RequestMapping("/inner")
public class JudgeInnerController implements JudgeFeignClient {
    @Resource
    private JudgeService judgeService;
    @Override
    @PostMapping("/do")
   public QuestionSubmit doJudge(@RequestParam("questionSubmitId") Long questionSubmitId){
       return judgeService.doJudge(questionSubmitId);
    }
}
